// CWAuctionInterface.h
//  CWAuctionInterface.h
//  CWAuctionSDK
//
//  Created by Lone on 2017/12/29.
//  Copyright © 2017年 carwin. All rights reserved.
//

#import <Foundation/Foundation.h>

@interface CWAuctionInterface : NSObject

/**
 * 用户是否登录 YES 已经登录可以正常使用
 */
+ (BOOL)userIsLogin;


/**
 1.1.模拟用户登录接口
 
 @param mobile 手机号码
 @param realityName 用户名(用于显示)
 @param isCanAuction 是否能发拍
 @param operateCityName 经营城市
 @param detailedAddress 详细地址
 @param institutionID 机构ID
 @param isProduction 是否生产环境?  1:是  0:否
 @param result 登录成功 status = YES 登录失败 status = NO, 失败原因可以查看error.code error.description
 */
+ (void)syncUserMessageWithMobile:(NSString *)mobile
                      realityName:(NSString *)realityName
                     isCanAuction:(NSString *)isCanAuction
                  operateCityName:(NSString *)operateCityName
                  detailedAddress:(NSString *)detailedAddress
                     isProduction:(NSInteger )isProduction
                           result:(void(^)(BOOL status, NSError *error))result;


/**
 1.2. 第三方用户接入验证
 
 @param identityId 第三方唯一标识
 @param isProduction 是否生产环境?  1:是  0:否
 @param result 登录成功 status = YES 登录失败 status = NO, 失败原因可以查看error.code error.description
 */
+ (void)syncUserMessageWithIdentityId:(NSString *)identityId
                         isProduction:(NSInteger )isProduction
                               result:(void(^)(BOOL status, NSError *error))result;






/**
 * 2.建立服务端通信
 *
 * - (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions 调用
 */
+ (void)startServiceConnect;

/**
 * 3.服务端通信重连
 *
 * applicationDidBecomeAc、tive:(UIApplication *)application 调用
 */
+ (void)serviceReconnect;

/**
 * 4.获取场次列表
 */
+ (UIViewController *)getAuctionSessionControlView;

/**
 * 5.获取出价车辆列表
 */
+ (UIViewController *)getAuctionBidCarListControlView;

/**
 * 6.获取中标的车辆列表
 */
+ (UIViewController *)getAuctionBibSuccessControlView;

/**
 * 7.获取关注的车辆列表
 */
+ (UIViewController *)getAuctionAttentionControlView;

/**
 * 8.如果未绑定,请先调用开通服务
 */
+ (UIViewController *)getOpenServiceControlView;

/**
 * 9.如果收到联盟拍类型消息,请调用此接口,打开相关场次,车辆;
 */
+ (UIViewController *)getMessageToShowAuctionInfoWithPid:(NSInteger )pid
                                       pushMessageTypeID:(NSInteger )pushMessageTypeID;








@end

